package com.ai.imagetext.dto;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 * 简单响应类，避免复杂对象序列化问题
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class SimpleResponse<T> {
    private boolean success;
    private String message;
    private T data;
    
    public static <T> SimpleResponse<T> success(String message, T data) {
        return new SimpleResponse<>(true, message, data);
    }
    
    public static <T> SimpleResponse<T> error(String message) {
        return new SimpleResponse<>(false, message, null);
    }
}